﻿<%@ Page Title="Home Page" Language="vb" MasterPageFile="~/Site.Master" AutoEventWireup="false"
    CodeBehind="Default.aspx.vb" Inherits="webscripting2013._Default" %>

<asp:Content ID="HeaderContent" runat="server" ContentPlaceHolderID="HeadContent">
</asp:Content>
<asp:Content ID="BodyContent" runat="server" ContentPlaceHolderID="MainContent">
    <br />
<br />
<br />
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
    DataKeyNames="ID" DataSourceID="SqlDataSource1" AllowSorting="True" CellPadding="4" 
        ForeColor="#333333" GridLines="None">
    <AlternatingRowStyle BackColor="White" />
    <Columns>
        <asp:HyperLinkField DataNavigateUrlFields="InfoUrl" 
            DataNavigateUrlFormatString="{0}" DataTextField="ModelName" HeaderText="Info" />
        <asp:BoundField DataField="ModelYear" HeaderText="ModelYear" 
            SortExpression="ModelYear" />
        <asp:BoundField DataField="CC" HeaderText="CC" SortExpression="CC" />
        <asp:BoundField DataField="Make" HeaderText="Make" 
            SortExpression="Make" />
        <asp:BoundField DataField="Condition" HeaderText="Condition" 
            SortExpression="Condition" />
        <asp:BoundField DataField="Color" HeaderText="Color" 
            SortExpression="Color" />
        <asp:BoundField DataField="Registration" HeaderText="Registration" 
            SortExpression="Registration" />
        <asp:BoundField DataField="Price" HeaderText="Price" 
            SortExpression="Price" />
        <asp:BoundField DataField="ContactNumber" HeaderText="ContactNumber" 
            SortExpression="ContactNumber" />
        <asp:BoundField DataField="InfoUrl" HeaderText="InfoUrl" 
            SortExpression="InfoUrl" />
        <asp:HyperLinkField DataNavigateUrlFields="SellerPost" 
            DataNavigateUrlFormatString="http://maps.google.co.uk/?q={0}" 
            DataTextField="SellerPost" HeaderText="Location" />
        <asp:ImageField DataImageUrlField="Picture" HeaderText="Picture">
            <ControlStyle Height="100px" Width="100px" />
        </asp:ImageField>
        <asp:HyperLinkField DataNavigateUrlFields="ID" 
            DataNavigateUrlFormatString="detail.aspx/?ID={0}" HeaderText="Detail" 
            Text="Detail" />
    </Columns>
    <EditRowStyle BackColor="#7C6F57" />
    <FooterStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
    <HeaderStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
    <PagerStyle BackColor="#666666" ForeColor="White" HorizontalAlign="Center" />
    <RowStyle BackColor="#E3EAEB" />
    <SelectedRowStyle BackColor="#C5BBAF" Font-Bold="True" ForeColor="#333333" />
    <SortedAscendingCellStyle BackColor="#F8FAFA" />
    <SortedAscendingHeaderStyle BackColor="#246B61" />
    <SortedDescendingCellStyle BackColor="#D4DFE1" />
    <SortedDescendingHeaderStyle BackColor="#15524A" />
</asp:GridView>
    <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
        ConnectionString="<%$ ConnectionStrings:CarsConn %>" 
        ProviderName="<%$ ConnectionStrings:CarsConn.ProviderName %>" 
        SelectCommand="SELECT * FROM [ClassicCars]"></asp:SqlDataSource>
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
&nbsp;
</asp:Content>
